/* Copyright 2018 JDCLOUD.COM

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

http:#www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.

高可用组
高可用组相关接口

OpenAPI spec version: v1
Contact: 

NOTE: This class is auto generated by the jdcloud code generator program.
*/


#ifndef AgClient_h
#define AgClient_h


#import <JDCloudOCSDKCore/JDCloudOCSDKCore.h>
#import <JDCloudOCSDKAg/AgApiModel.h>

@interface AgClient : NSObject<JDCloudClient>{
    @private
    NSString* _userAgent;
    NSString* _serviceName;
    NSString* _version;
    }

    @property (strong,readonly,nonatomic) NSString* userAgent;

    @property (strong,readonly,nonatomic) NSString* serviceName;

    @property (strong,readonly,nonatomic) NSString* version;

    @property (strong,nonatomic) NSString* contentType;

    @property (strong,nonatomic) Credential* credential;

    @property (strong,nonatomic) SDKEnvironment* sdkEnvironment;

    @property (strong,nonatomic) NSMutableDictionary* customHeader;

    @property  (strong,nonatomic) NSString* httpRequestProtocol;

    -(void) addCustomerHeaderWithKey:(NSString*) key
    value:(NSString*) value;

    -(id)initWithGlobalConfig;

    -(id)initWithCredential:(Credential*)credential
    sdkEnvironment:(SDKEnvironment*)sdkEnvironment;
    -(id)initWithCredential:(Credential*)credential;
    /**
    updateAg sync request
    @param updateAgRequest request param
    @return key `statusCode` http request status code type is int
            `dataResult` the http request response data  type is NSData
            `requestError` the request error type is NSError
            `updateAgResponse` the request response data model
    */
    -(NSDictionary*) updateAgSyncWithRequest:(AgUpdateAgRequest*) updateAgRequest;

    -(void)updateAgAsyncWithRequest:(AgUpdateAgRequest*) updateAgRequest
    completionHandler:(void(^)(int statusCode,AgUpdateAgResponse* _Nullable updateAgResponse, NSData* _Nullable responseData,NSError * _Nullable error))completionHandler;
    /**
    deleteAg sync request
    @param deleteAgRequest request param
    @return key `statusCode` http request status code type is int
            `dataResult` the http request response data  type is NSData
            `requestError` the request error type is NSError
            `deleteAgResponse` the request response data model
    */
    -(NSDictionary*) deleteAgSyncWithRequest:(AgDeleteAgRequest*) deleteAgRequest;

    -(void)deleteAgAsyncWithRequest:(AgDeleteAgRequest*) deleteAgRequest
    completionHandler:(void(^)(int statusCode,AgDeleteAgResponse* _Nullable deleteAgResponse, NSData* _Nullable responseData,NSError * _Nullable error))completionHandler;
    /**
    setInstanceTemplate sync request
    @param setInstanceTemplateRequest request param
    @return key `statusCode` http request status code type is int
            `dataResult` the http request response data  type is NSData
            `requestError` the request error type is NSError
            `setInstanceTemplateResponse` the request response data model
    */
    -(NSDictionary*) setInstanceTemplateSyncWithRequest:(AgSetInstanceTemplateRequest*) setInstanceTemplateRequest;

    -(void)setInstanceTemplateAsyncWithRequest:(AgSetInstanceTemplateRequest*) setInstanceTemplateRequest
    completionHandler:(void(^)(int statusCode,AgSetInstanceTemplateResponse* _Nullable setInstanceTemplateResponse, NSData* _Nullable responseData,NSError * _Nullable error))completionHandler;
    /**
    describeQuotas sync request
    @param describeQuotasRequest request param
    @return key `statusCode` http request status code type is int
            `dataResult` the http request response data  type is NSData
            `requestError` the request error type is NSError
            `describeQuotasResponse` the request response data model
    */
    -(NSDictionary*) describeQuotasSyncWithRequest:(AgDescribeQuotasRequest*) describeQuotasRequest;

    -(void)describeQuotasAsyncWithRequest:(AgDescribeQuotasRequest*) describeQuotasRequest
    completionHandler:(void(^)(int statusCode,AgDescribeQuotasResponse* _Nullable describeQuotasResponse, NSData* _Nullable responseData,NSError * _Nullable error))completionHandler;
    /**
    abandonInstances sync request
    @param abandonInstancesRequest request param
    @return key `statusCode` http request status code type is int
            `dataResult` the http request response data  type is NSData
            `requestError` the request error type is NSError
            `abandonInstancesResponse` the request response data model
    */
    -(NSDictionary*) abandonInstancesSyncWithRequest:(AgAbandonInstancesRequest*) abandonInstancesRequest;

    -(void)abandonInstancesAsyncWithRequest:(AgAbandonInstancesRequest*) abandonInstancesRequest
    completionHandler:(void(^)(int statusCode,AgAbandonInstancesResponse* _Nullable abandonInstancesResponse, NSData* _Nullable responseData,NSError * _Nullable error))completionHandler;
    /**
    createAg sync request
    @param createAgRequest request param
    @return key `statusCode` http request status code type is int
            `dataResult` the http request response data  type is NSData
            `requestError` the request error type is NSError
            `createAgResponse` the request response data model
    */
    -(NSDictionary*) createAgSyncWithRequest:(AgCreateAgRequest*) createAgRequest;

    -(void)createAgAsyncWithRequest:(AgCreateAgRequest*) createAgRequest
    completionHandler:(void(^)(int statusCode,AgCreateAgResponse* _Nullable createAgResponse, NSData* _Nullable responseData,NSError * _Nullable error))completionHandler;
    /**
    describeAg sync request
    @param describeAgRequest request param
    @return key `statusCode` http request status code type is int
            `dataResult` the http request response data  type is NSData
            `requestError` the request error type is NSError
            `describeAgResponse` the request response data model
    */
    -(NSDictionary*) describeAgSyncWithRequest:(AgDescribeAgRequest*) describeAgRequest;

    -(void)describeAgAsyncWithRequest:(AgDescribeAgRequest*) describeAgRequest
    completionHandler:(void(^)(int statusCode,AgDescribeAgResponse* _Nullable describeAgResponse, NSData* _Nullable responseData,NSError * _Nullable error))completionHandler;
    /**
    describeAgs sync request
    @param describeAgsRequest request param
    @return key `statusCode` http request status code type is int
            `dataResult` the http request response data  type is NSData
            `requestError` the request error type is NSError
            `describeAgsResponse` the request response data model
    */
    -(NSDictionary*) describeAgsSyncWithRequest:(AgDescribeAgsRequest*) describeAgsRequest;

    -(void)describeAgsAsyncWithRequest:(AgDescribeAgsRequest*) describeAgsRequest
    completionHandler:(void(^)(int statusCode,AgDescribeAgsResponse* _Nullable describeAgsResponse, NSData* _Nullable responseData,NSError * _Nullable error))completionHandler;

    /**
    ag common sync request
    @param  jdcloudDataRequest request param
    @return key `statusCode` http request status code type is int
            `dataResult` the http request response data  type is NSData
            `requestError` the request error type is NSError
    */
    -(NSDictionary*) agCommonSyncWithRequest:(JDCloudDataRequest*) jdcloudDataRequest
                                           url:(NSString*) url
                                        method:(NSString*) method;

    -(void)agCommonAsyncWithRequest:(JDCloudDataRequest*) jdcloudDataRequest
                                  url:(NSString*) url
                               method:(NSString*) method
                    completionHandler:(void(^)(int statusCode, NSData* _Nullable responseData,NSError * _Nullable error))completionHandler;

    @end


    #endif /* AgClient_h */
